package com.lboyang.cloud.config;

import org.springframework.cloud.client.loadbalancer.LoadBalanced;
import org.springframework.context.annotation.Bean;
import org.springframework.context.annotation.Configuration;
import org.springframework.web.client.RestTemplate;

/**
 * @Description:
 * @Author: Aiguodala
 * @CreateDate: 2021/4/24 17:37
 */

@Configuration
public class ApplicationContextConfig {

    @Bean
    @LoadBalanced // 提供负载均衡
    public RestTemplate getRestTemplate() {
        return new RestTemplate();
    }
}


